// 引入 request 方法，假设 request 方法已经定义在某个工具文件中
import request from '/@/utils/request';

// 定义 API 路径枚举
enum Api {
    SendEmail = '/sysEmail/sendEmail/{content}/{title}/{toEmail}',
}

// 发送邮件
export const apiSysEmailSendEmailContentTitleToEmailPost = (content: string, title: string, toEmail: string) =>
    request({
        url: Api.SendEmail.replace('{content}', encodeURIComponent(content))
                          .replace('{title}', encodeURIComponent(title))
                          .replace('{toEmail}', encodeURIComponent(toEmail)),
        method: 'post',
    });